﻿@{    
    var menus = Web.Menus.MenuHelper.GetAllMenus(Url, (string)ViewBag.Link);
    var activeMenu = menus.FirstOrDefault(item => item.IsActive);
}
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>泓源国际集团</title>
    <link href="~/Content/bootstrap/css/bootstrap.min.css" rel="stylesheet" />
    <link href="~/Styles/style.css" rel="stylesheet" />
    <script type="text/javascript" src="~/Scripts/jquery-1.7.1.min.js"></script>
    <script type="text/javascript" src="~/Scripts/common.js"></script>
    <script src="~/Content/bootstrap/js/bootstrap.min.js"></script>
    @RenderSection("Style", false)
</head>
<body>
    <div class="navbar navbar-fixed-top">
        <div class="navbar-inner">
            <div class="container">
                <div class="nav-collapse collapse">
                    <ul class="nav">
                        @foreach (var item in menus)
                        {
                            <li class="@(item.IsActive ? "active" : "")">
                                <a href="@item.Link">@item.Name</a>
                            </li>
                        }
                    </ul>
                    <div style="position: absolute; right: 30px;">
                        <div class="btn-group">
                            <button class="btn btn-success dropdown-toggle" data-toggle="dropdown">@ViewBag.UserName <span class="caret"></span></button>
                            <ul class="dropdown-menu">
                                <li><a href="/system/logout">退出</a></li>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
        </div>

    </div>


    <div class="container-fluid bodywarpper">
        <div class="row-fluid">
            <div class="span2">
                <ul class="nav nav-list">
                    @foreach (var item in activeMenu.SubMenus)
                    {            
                        <li class="@(item.IsActive ? "active" : "")"><a href="@item.Link">@item.Name</a></li> 
                    }
                </ul>
            </div>
            <div class="span10">
                <div class="right-content">
                    @RenderBody()
                </div>
            </div>
        </div>
    </div>

    <div class="footer navbar-fixed-bottom">
        <div>
            <span class="copyright">粤ICP备8888号 版权所有 © 泓源国际集团控股有限公司</span>
            <span class="comlink"><a href="#">法律声明</a> <a href="#">服务条款</a> <a href="#">联系我们</a></span>
        </div>
    </div>
    @RenderSection("Script", false)
</body>
</html>
